﻿using System.Xml.Serialization;

namespace FuiouPay.Models.Response {
    [XmlRoot("xml")]
    public class MicropayResponseInfo : FuiouResponseInfo {
        /// <summary>
        /// 订单金额，分为单位的整数
        /// </summary>
        [XmlElement("total_amount")]
        public string TotalAmount { get; set; }

        /// <summary>
        /// 买家在渠道账号
        /// </summary>
        [XmlElement("buyer_id")]
        public string BuyerId { get; set; }

        /// <summary>
        /// 附加数据
        /// </summary>
        [XmlElement("addn_inf")]
        public string AddnInf { get; set; }

        /// <summary>
        /// 富友生成的订单号,需要商户与商户订单号进行关联
        /// </summary>
        [XmlElement("reserved_fy_order_no")]
        public string ReservedFyOrderNo { get; set; }

        /// <summary>
        /// 商户订单号, 商户系统内部的订单号
        /// </summary>
        [XmlElement("reserved_mchnt_order_no")]
        public string ReservedMchntOrderNo { get; set; }

        /// <summary>
        /// 富友交易日期
        /// </summary>
        [XmlElement("reserved_fy_settle_dt")]
        public string ReservedFySettleDt { get; set; }

        /// <summary>
        /// 优惠金额（分）
        /// </summary>
        [XmlElement("reserved_coupon_fee")]
        public string ReservedCouponFee { get; set; }

        /// <summary>
        /// 买家在渠道登录账号
        /// </summary>
        [XmlElement("reserved_buyer_logon_id")]
        public string ReservedBuyerLogonId { get; set; }

        /// <summary>
        /// 支付宝交易资金渠道,详细渠道
        /// </summary>
        [XmlElement("reserved_fund_bill_list")]
        public string ReservedFundBillList { get; set; }

        /// <summary>
        /// 富友系统内部追踪号
        /// </summary>
        [XmlElement("reserved_fy_trace_no")]
        public string ReservedFyTraceNo { get; set; }

        /// <summary>
        /// 条码流水号，用户账单二维码对应的流水
        /// </summary>
        [XmlElement("reserved_channel_order_id")]
        public string ReservedChannelOrderId { get; set; }

        /// <summary>
        /// 1：表示信用卡或者花呗
        /// 0：表示其他(非信用方式)
        /// 不填，表示未知
        /// </summary>
        [XmlElement("reserved_is_credit")]
        public string ReservedIsCredit { get; set; }

        /// <summary>
        /// 用户支付时间yyyyMMddHHmmss
        /// </summary>
        [XmlElement("reserved_txn_fin_ts")]
        public string ReservedTxnFinTs { get; set; }

        /// <summary>
        /// 应结算订单金额，以分为单位的整数
        /// 只有成功交易才会返回
        /// 如果使用了商户免充值优惠券，该值为订单金额-商户免充值
        /// 如果没有使用商户免充值，该值等于订单金额
        /// </summary>
        [XmlElement("reserved_settlement_amt")]
        public string ReservedSettlementAmt { get; set; }

        /// <summary>
        /// 付款方式
        /// </summary>
        [XmlElement("reserved_bank_type")]
        public string ReservedBankType { get; set; }

        /// <summary>
        /// 微信营销详情
        /// [{ "activity_id":"12345", "amount":"1", "merchant_contribute":"1", "name":"BSagiiBBXm", "other_contribute":"0", "promotion_id":"10000", "scope":"GLOBAL", "type":"DISCOUNT", "wxpay_contribute":"0" }]
        /// </summary>
        [XmlElement("reserved_promotion_detail")]
        public string ReservedPromotionDetail { get; set; }
    }
}
